<template>
  <div>

  </div>
</template>

<script>
export default {
  name: "index",
  mounted() {
    // 跳转判断
    this.jumpIndex()
  },
  methods:{
    jumpIndex(){
      // 获取用户的权限
      const roles = this.$store.getters.roles

      const route = this.$store.getters.permission_add_routes.find(item=> item.path !== '/')
      if(route){
        this.$router.push({
          path: route.path
        })
      }
      // 默认都跳转到订单列表

      // if(roles.indexOf('editor') !== -1){
      //
      // }else{
      //   this.$router.push({
      //     path:'/404',
      //   })
      // }

      console.log("跳转页面")
    }
  },
}
</script>

<style scoped>

</style>
